<?php

/**
 * Created by JetBrains PhpStorm.
 * User: GMC02
 * Date: 10/4/13
 * Time: 5:16 PM
 * To change this template use File | Settings | File Templates.
 */
class Mailer {
    public static function sendEmail($to, $subject, $body) {
        Yii::app()->mailer->AddAddress($to);
        Yii::app()->mailer->Subject = $subject;
        Yii::app()->mailer->MsgHTML($body);
        Yii::app()->mailer->Send();
        Yii::app()->mailer->ClearAllRecipients();
    }
}